package com.shirodemo.service.impl;

import com.shirodemo.mapper.RoleMapper;
import com.shirodemo.pojo.Role;
import com.shirodemo.service.RoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by 追风少年
 *
 * @email doubihah@foxmail.com
 * @create 2017/12/13 13:27
 **/
@Service
public class RoleServiceImpl implements RoleService {

    @Autowired
    private RoleMapper roleMapper;

    @Override
    public List<Role> findRolesByUserId(String userId) {
        List<Role> roles = roleMapper.selectByUserId(userId);
        return roles;
    }

}
